package com.kelvin.backend.common.web.response;

/**
 * <p>Title: BaseCode</p>
 * <p>Description: </p>
 *
 * @author Kelvin.Chen
 * @datetime 2021/7/8 15:20
 */
public enum BaseCode implements CodeMsg<String> {

    SUCCESS("00000", "操作成功"),
    FAIL("11111", "操作失败"),
    ERROR("22222", "系统异常，请联系管理员")
    ;

    private String code;
    private String msg;

    BaseCode(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    @Override
    public String code() {
        return this.code;
    }

    @Override
    public String msg() {
        return this.msg;
    }
}
